package com.easyweb.session;

import com.easyweb.entity.*;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.framework.EntityHome;

@Name("ulkeHome")
public class UlkeHome extends EntityHome<Ulke> {

	public void setUlkeId(BigDecimal id) {
		setId(id);
	}

	public BigDecimal getUlkeId() {
		return (BigDecimal) getId();
	}

	@Override
	protected Ulke createInstance() {
		Ulke ulke = new Ulke();
		return ulke;
	}

	public void load() {
		if (isIdDefined()) {
			wire();
		}
	}

	public void wire() {
		getInstance();
	}

	public boolean isWired() {
		return true;
	}

	public Ulke getDefinedInstance() {
		return isIdDefined() ? getInstance() : null;
	}

	public List<Iller> getIllers() {
		return getInstance() == null ? null : new ArrayList<Iller>(
				getInstance().getIllers());
	}

}
